<div class="list-group list-group-flush">
    <div data-toggle="collapse" data-target="#{{ collapse_id }}" class="list-group-item d-flex justify-content-between align-items-center border-0">
        <span>{{ first_item | safe }}</span>
        <span class="btn-group">
            {% set btn_class = btn_class if btn_class else 'primary' %}
            <span class="btn btn-sm btn-{{ btn_class }}"><i class="fas fa-list-ul"></i></span>
            <span class="btn btn-sm btn-{{ btn_class }}">{{ input_data | length }}</span>
        </span>
    </div>
    <div id="{{ collapse_id }}" class="collapse">
        {% for item in input_data %}
            <div class="list-group-item border-top">{{ item | safe }}</div>
        {% endfor %}
    </div>
</div>
